class CreateProducts < ActiveRecord::Migration
  def change
    create_table :products do |t|
      t.references :merchant
      t.references :merchant_product_category
      t.string :product_name
      t.text :product_description
      t.float :price
      t.float :discount
      t.boolean :active

      t.timestamps
    end
    add_index :products, :merchant_id
    add_index :products, :merchant_product_category_id
  end
end
